	@include('admin.head')
	<div class="container">
		<div class="row">
			@include('admin.side')
			<div class="col-md-10" id="content-wrapper">
				<div class="row">
					<div class="col-xs-12">
						<div class="main-box clearfix">
							<div class="clearfix">
								<h2 class="pull-left">设备详细</h2>
							</div>
							<div class="panel panel-default">
								<div class="panel-body">
								  	<div class="row">
								  		<!-- <div class="col-xs-4">
								  			<button class="btn btn-primary pull_right" pid="" id="doEdit"><i class="fa fa-eye"></i></i> 审核</button>
								  		</div> -->
								  	</div>
								  	<div class="form-horizontal">
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备名称:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["name"]%>
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备领域:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["device_domain"]["domain"]["cate_name"]%>
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备型号:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["model"]%>
											</div>
										</div>
										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">生产商:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["creator"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备价格最低价:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["minimize_price"]%>

											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备价格最高价:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["maximize_price"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">认证信息:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["auth_info"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">产品标准:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["standard"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用技术:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["device_tech"]["tech"]["cate_name"]%>
											</div>
										</div>


										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用领域:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["device_domain"]["domain"]["cate_name"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">应用主体:</label>
											<div class="col-xs-5 uc_value _left">
											@foreach($data["mainbody"] as $value)
											<%$value["main"]["name"]%> 
											@endforeach
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备图片:</label>
											<div class="col-xs-5 uc_value _left">
											@if (isset($data["image"]) && $data["image"])
											<img src="<%url('images')%>/<%$data['uid']%>/<%env('DEVICE_DIR')%>/<%$data['image']%>" alt="" width="100">
											@endif
											</div>
										</div>


										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">节能效率:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["efficiency"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备描述:</label>
											<div class="col-xs-5 uc_value _left">
											<%$data["description"]%>
											</div>
										</div>

										<div class="form-group">
											<label class="col-xs-4 control-label no_padding_top ">设备原理:</label>
											<div class="col-xs-5 uc_value _left" id="theory">
											</div>
										</div>

									    <div class="form-group">
								      		<label for="select" class="col-xs-4 control-label no_padding_right">审核状态:</label>
									      	<div class="col-xs-2">
									        <select class="form-control input_size" name="verify_state">
									          <option value="0" @if($data['verify_state'] == 0) selected @endif >待审核</option>
									          <option value="1" @if($data['verify_state'] == 1) selected @endif >审核通过</option>
									          <option value="2" @if($data['verify_state'] == 2) selected @endif >审核不通过</option>
									        </select>
									      </div>
									      <div class="col-xs-3 no_padding_both">
									      	<button class="btn btn-primary" id="audit">提交</button>
									      </div>
								    	</div>

									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	@include("admin.footer")
	@include("admin.common")
</body>
<script type="text/javascript">
var did = "<%Input::get('did')%>";
$("#theory").html(decodeURIComponent("<%$data['theory']%>"));

$("#audit").click(function(){
	var state = $("select[name='verify_state']").val();
	$.post("audit", {did : did, state : state}, function (data){
		if(data.success)
		{
			success("", "修改成功");
			setTimeout(function(){
				window.location.href="../device";
			}, 2000)
		}
	})
})

</script>

</html>